﻿using Vigenere_cipher.Models;

namespace Vigenere_cipher
{
    internal class Program
    {
        /// <summary>
        /// 维吉尼亚密码的加密
        /// </summary>
        /// <param name="args"></param>
        static void Main(string[] args)
        {
            //输入明文
            Console.Write("请输入要加密的字符串:");
            string input =Console.ReadLine();           
            //输入key
            Console.Write("请输入密钥:");
            string key = Console.ReadLine();
            //加密
            MyEncoder myEncoder = new MyEncoder();
            myEncoder.PlainText=input;                        
            myEncoder.Key=key;
            myEncoder.Ecode();           
            //输出密文
            Console.WriteLine($"加密后的密文：{myEncoder.CipherText}");
        }       
    }
}